SOInetNtoP


C Specification

#include <dolphin/socket.h>

#define SO_INET_ADDRSTRLEN    16
const char* SOInetNtoP ( int af, const void* src, char* dst, unsigned len );

Description

SOInetNtoP() converts a numeric address to a suitable text string.

Arguments

af The family of the address (must be SO_PF_INET).
src A pointer to a buffer holding an IPv4 address.
dst A pointer to a buffer where the function stores the resulting text string. (e.g., ddd.ddd.ddd.ddd)
len The buffer size of dst. len should be large enough to hold the text string (INET_ADDRSTRLEN for SO_PF_INET).

Return Values

A pointer to the buffer containing the text string if the conversion succeeds. Otherwise, NULL.

See Also

SOInetPtoN()